﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace GRIP
{
    /// <summary>
    /// Modes for finger tracking
    /// </summary>
    public enum FingerMode
    {
        /// <summary>
        /// Finger tracking will be disabled; only the SDK's skeleton points will be used.
        /// </summary>
        Off,

        /// <summary>
        /// Finger tracking will be synchronized with the skeleton, so the adapter will wait until
        /// tracking is complete for each frame before sending a new contact frame.
        /// </summary>
        Synchronous,

        /// <summary>
        /// Finger tracking will be asynchronous and decoupled from the rest of the skeleton data.
        /// The finger points and skeleton points update independently, whenever they are ready.
        /// </summary>
        Asynchronous
    };

    /// <summary>
    /// Modes for color-to-depth alignment
    /// </summary>
    public enum ColorAlignmentMode
    {
        /// <summary>
        /// Color alignment will not be used.
        /// </summary>
        Off,

        /// <summary>
        /// Color alignment will use a pre-defined depth map.
        /// </summary>
        FixedDepthMap,

        /// <summary>
        /// Each color image will be dynamically aligned based on the corresponding depth image.
        /// </summary>
        RealtimeDepthMap
    }

    /// <summary>
    /// Modes for Kinect's color camera
    /// </summary>
    public enum ColorMode
    {
        /// <summary>
        /// Color camera will be disabled.
        /// </summary>
        Off,

        /// <summary>
        /// Color camera will be enabled at 640x480, 30 FPS.
        /// The pixel format will be RGBA, 32bpp. Alpha is unused.
        /// </summary>
        Rgb_640x480_30FPS,

        /// <summary>
        /// Color camera will be enabled at 1280x960, 12 FPS.
        /// The pixel format will be RGBA, 32bpp. Alpha is unused.
        /// </summary>
        Rgb_1280x960_12FPS,

        /// <summary>
        /// Color camera will be enabled at 640x480, 15 FPS.
        /// The Kinect will deliver YUV images, which will be converted to RGBA 32 bpp.
        /// Alpha is unused.
        /// </summary>
        YuvToRgb_640x480_15FPS,

        /// <summary>
        /// Color camera will be enabled at 640x480, 15 FPS.
        /// The pixel format will be UYVY, 16 bpp.
        /// </summary>
        YuvRaw_640x480_15FPS
    }

    /// <summary>
    /// Modes for Kinect's depth camera
    /// </summary>
    public enum DepthMode
    {
        /// <summary>
        /// Depth camera will be disabled
        /// </summary>
        Off,

        /// <summary>
        /// Depth camera will be enabled at 640x480, 30 FPS.
        /// MSB is unused, depth is stored in the next 12 bits,
        /// and the remaining 3 bits store the player index.
        /// </summary>
        On_640x480_30FPS,

        /// <summary>
        /// Depth camera will be enabled at 320x240, 30 FPS.
        /// MSB is unused, depth is stored in the next 12 bits,
        /// and the remaining 3 bits store the player index.
        /// </summary>
        On_320x240_30FPS,

        /// <summary>
        /// Depth camera will be enabled at 80x60, 30 FPS.
        /// MSB is unused, depth is stored in the next 12 bits,
        /// and the remaining 3 bits store the player index.
        /// </summary>
        On_80x60_30FPS
    }

    /// <summary>
    /// Modes for background subtraction
    /// </summary>
    public enum BackgroundSubtractionMode
    {
        /// <summary>
        /// Background subtraction will not be used.
        /// </summary>
        Off,

        /// <summary>
        /// Remove everything but the closest person from the depth image.
        /// The depth image will no longer have player indices, so the first
        /// 12 bits represent depth.
        /// Any pixel not belonging to the closest person will be set to zero.
        /// </summary>
        ClosestPerson,

        /// <summary>
        /// Remove the background from the depth image, preserving players.
        /// The depth image will retain its original format, with player indices.
        /// Any pixel not belonging to a person will be set to zero.
        /// </summary>
        AllPeople,

        /// <summary>
        /// Remove everything but the closest person from the depth image.
        /// The depth image will no longer have player indices, so the first
        /// 12 bits represent depth.
        /// Any pixel not belonging to the closest person will be set to zero.
        /// For convenience, this will also construct an alpha mask out of the
        /// depth image. User pixels will be set to 255, non-user pixels
        /// will be set to zero.
        /// </summary>
        ClosestPersonWithAlpha,

        /// <summary>
        /// Remove the background from the depth image, preserving players.
        /// The depth image will retain its original format, with player indices.
        /// Any pixel not belonging to a person will be set to zero.
        /// For convenience, this will also construct an alpha mask out of the
        /// depth image. User pixels will be set to 255, non-user pixels
        /// will be set to zero.
        /// </summary>
        AllPeopleWithAlpha
    }
}
